import { _decorator, Component, director, Node } from 'cc';
import { SceneManager } from './SceneManager';
import { SceneEnum } from '../Enum';
import DataManger from '../RunTime/DataManager';
const { ccclass, property } = _decorator;

@ccclass('MenuSceneManager')
export class MenuSceneManager extends SceneManager {
    type: SceneEnum = SceneEnum.Menu
    
    handleNewGame() {
        DataManger.Instance.reset()
        director.loadScene(SceneEnum.H1)
    }

    handleContinue() {
        DataManger.Instance.restore()
        director.loadScene(DataManger.Instance.curScene)
    }

    rendor(): void {
        
    }
}
